import { IFeidaoAiBrowserComponent } from '@dfeidao/atom-web/interfaces';
import local_get from '@dfeidao/atom-web/local/get';
import local_set from '@dfeidao/atom-web/local/set';
import render from '@dfeidao/atom-web/render/render';
import P01 from './P01';
// 删除控制点
export default async function a007(fd: IFeidaoAiBrowserComponent, args?: { currentTarget: HTMLElement }) {
	const data: [{}] = local_get(fd, "data");
	const new_data = new Array();
	Array.from(data).forEach((a) => {
		if (JSON.stringify(a) !== args.currentTarget.getAttribute('data')) {
			new_data.push(a);
		}
	});
	render(fd, new_data, P01, 'P01', 'inner');
	local_set(fd, "data", new_data);
}
